#pragma once

#include <vector>
#include "Geometry.h"
#include "NearestNeighbors.h"
#include "Environment2D.h"
#include <time.h>

class RoadMap
{
public:
	RoadMap(void);
	virtual ~RoadMap(void);

	void init(float minX, float maxX, float minY, float maxY);

	void addVertex(const Vector2& vertex, const Environment2D& environment, float radius, clock_t& knnTime, clock_t& linkTime);
	void render();

	int getNumVertices() const { return vertices_.size(); }
	int getNumEdges() const { return edges_.size(); }

protected:
	std::vector<Vector2> vertices_;
	std::vector<std::pair<int, int> > edges_;

	NearestNeighbors nn_;
};

